home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1997 April / EnigmA AMIGA RUN 17 (1997)(G.R. Edizioni)(IT)[!][issue 1997-04][EAR-CD].iso / EARCD / biz / swood / FW_Font.lha / FW_Font / FontLook-Auto.fwrexx.long < prev    next >
Text File  |  1996-12-15  |  7KB  |  274 lines

  1. /* Hiermit erhält man eine Übersicht über seine gesamten Zeichensätze*/
  2. /* © Heiko Schröder / 15.12.96 / Mail: s93324@fh-telekom-leipzig.de */
  3. R='0A'X
  4.  
  5. Address='FinalW'
  6. Options results
  7.  
  8. STATUS PORTNAME
  9. FW = result
  10. address = FW
  11.  
  12. SIGNAL ON BREAK_C
  13.  
  14. 'ShowMessage 2 1 "FontLook - Auto V2.60" "für Font-Verzeichnisse..." "(©) Heiko Schröder - 15.12.96" ":-)" "Ok" "(-:"'
  15. 'ShowMessage 1 1 "A C H T U N G !" "Das Makro benötigt ein leeres Dokument." "Ihr jetziges Dokument wird gelöscht!" "Ja" "Abbruch" ""'
  16. if result=2 then call BREAK_C
  17. Cleardoc Force
  18.  
  19. 'ShowMessage 2 1 "Codes oder Layout" "" "" "Codes" "Layout" ""'
  20. cl=result
  21.  
  22. 'ShowMessage 2 1 "Wie soll die" "Bilschirmausgabe erfolgen?" "" "Normal" "Speed" ""'
  23. ba=result
  24.  
  25.  
  26. /*----- REXXREQTOOLS -----*/
  27.  
  28. Temp="ram:fonts"
  29. if ~show('L',"rexxreqtools.library") then do
  30.    if ~addlib('rexxreqtools.library',0,-30,0) then do
  31.       'ShowMessage 1 1 "Fehler...." "Benötige RexxReqTools.library" " A B B R U C H ! !" "Okay" "" ""'
  32.       exit
  33.    end
  34. end
  35.  
  36. dir=rtfilerequest(,,"Verzeichnis auswählen...","»·Start·«","rtfi_flags = freqf_nofiles")
  37. if dir="" then do
  38.    'ShowMessage 1 1 "Kein Verzeichnis ausgewählt!" "   A B B R U C H ! !" "" "Okay" "" ""'
  39.    exit
  40. end
  41. dir=d2c(34)||dir||d2c(34)
  42. address command 'list ' dir || ' to=' Temp || ' files lformat "%s%s"'
  43.  
  44. If OPEN('file',Temp,"R") then
  45. If Seek("file",0,"E")=0 then do
  46.    'ShowMessage 1 1 "Verzeichnis ist leer" " A B B R U C H ! !" "" "Okay" "" ""'
  47.    address "REXX"
  48.    close("file")
  49.    EXIT
  50. end
  51.  
  52. address "REXX"
  53. close("file")
  54. address command 'sort ' Temp Temp
  55. OPEN('file',Temp, "R")
  56.  
  57. address(FW)
  58. 'ShowMessage 1 1 "Benötigen Sie Locher-Marken?" "" "" "Ja" "Nein" ""'
  59. lm=result
  60. 'ShowMessage 1 1 "Wie geht es weiter?" "" "" "Speichern" "Speichern & Drucken" "Drucken"'
  61. wgw=result
  62.  
  63.  
  64. /*----- Schleife bis alle Fonts ausgegeben worden sind -----*/
  65.  
  66. DO WHILE 1
  67.     FontName=ReadLn('file')
  68.     IF EOF('file') THEN do
  69.       address "REXX"
  70.       close('file')
  71.       call Ende
  72.    End
  73.  
  74.    TextTool
  75.    Font FontName
  76.    a=RC
  77.    If a=0 then do                  /* Kann FW den Font verarbeiten?*/
  78.  
  79.       Type d2c(32)
  80.       BackSpace
  81.       status FontPath
  82.       FullFontName=result
  83.       pos=LASTPOS('/', FullFontName)
  84.       IF (pos~=0) THEN
  85.          FontName=RIGHT(FullFontName, LENGTH(FullFontName)-pos)
  86.       ELSE DO
  87.          pos=LASTPOS(':', FullFontName)
  88.          IF (pos~=0) THEN
  89.             FontName=Right(FullFontName, LENGTH(FullFontName)-pos)
  90.          ELSE
  91.          EXIT
  92.       END
  93.       IF ba=2 THEN DO
  94.          View 20
  95.       End
  96.  
  97.       GraphicTool
  98.       LinePrefs LineWt .5
  99.  
  100.       If lm=1 then DrawLine 1 .5 14.85 1 14.85
  101.  
  102.       If cl=1 then do
  103.          DrawLine 1 2 3.5 20 3.5
  104.          DrawLine 1 2 26 20 26
  105.          TextTool
  106.          Pagesetup Pagetype A4 Orient Tall Top 0 Bottom 2.54 Left 0 Right 0
  107.          SectionSetup Top 2.54 Bottom 2.54 Inside 2 Outside 1
  108.  
  109.          Do i=0 to 13
  110.             SetTab i*1.3+0.8 Right
  111.          End
  112.  
  113.          NameFont="FWDocs/Codes-" || FontName
  114.          Justify Center
  115.          Font Softsans
  116.          FontSize 18
  117.          Type FontName||R||R
  118.  
  119.          Justify Left
  120.  
  121.          a=0
  122.  
  123.          DO w=1 to 15
  124.  
  125.             Font Softsans
  126.             FontSize 8
  127.             DO x=a+33 to a+46
  128.                 Type d2c(9) || x || d2c(32) || d2c(x)
  129.             END
  130.  
  131.             Type R
  132.  
  133.             Font FontName
  134.             FontSize 24
  135.             DO x=a+33 to a+46
  136.                 Type d2c(9)
  137.                Type d2c(x)
  138.             END
  139.  
  140.             Type R
  141.  
  142.             a=a+14
  143.  
  144.          END
  145.  
  146.          Font Softsans
  147.          FontSize 8
  148.          DO x=a+33 to a+45
  149.              Type d2c(9) || x || d2c(32) || d2c(x)
  150.          END
  151.  
  152.          Type R
  153.  
  154.          Font FontName
  155.          FontSize 24
  156.          DO x=a+33 to a+45
  157.              Type d2c(9)
  158.             Type d2c(x)
  159.          END
  160.          Type R
  161.          FontSize 12
  162.          Type d2c(9)||R
  163.          Font Softsans
  164.  
  165.          FontSize 8
  166.          Justify Right
  167.          Type Date(E)
  168.  
  169.       END
  170.  
  171.       If cl=2 then do
  172.          DrawLine 1 2 3.4 20 3.4
  173.          TextTool
  174.          Pagesetup Pagetype A4 Orient Tall Pages RightOnly Top 0 Bottom 2.54 Left 0 Right 0
  175.          SectionSetup Top 2.54 Bottom 2.54 Inside 2 Outside 1
  176.  
  177.          Justify Center
  178.          NameFont="FWDocs/Layout-" || FontName
  179.          Font Softsans
  180.          FontSize 18
  181.          Type FontName||R
  182.  
  183.          Justify Left
  184.          Font FontName
  185.          FontSize 8
  186.          Type R||"This is 8-point type - not easy to read!"||R
  187.  
  188.          FontSize 9
  189.          Type "9-Point type is about the smallest readable size."||R
  190.  
  191.          FontSize 10
  192.          Type "With 10-point type, we have a normal text size."||R
  193.  
  194.          FontSize 12
  195.          Type "With some Fonts, 12-point type is easier to read."||R
  196.  
  197.          FontSize 14
  198.          Type "14-point type is good for subheadings."||R
  199.  
  200.          FontSize 16
  201.          Type "For larger subheadings, try 16-point type."||R
  202.  
  203.          FontSize 18
  204.          Type "18-point type makes nice small headlines."||R
  205.  
  206.          FontSize 24
  207.          Type "24-point type is for medium headlines."||R
  208.  
  209.          FontSize 36
  210.          Type "36-point is for larger ones."||R
  211.  
  212.          FontSize 48
  213.          Type "48-point almost shouts!"||R
  214.  
  215.          FontSize 60
  216.          Type "60-point is huge!"||R
  217.  
  218.          FontSize 12
  219.          Font SoftSans
  220.          Type "NORMAL"||R
  221.          Font FontName
  222.          Type "ABCDEFGHIJKLMNOPQRSTUVWXYZ"||R
  223.          Type "abcdefghijklmnopqrstuvwxyz 1234567890 !@#$%^&*()-+=[]{}/:;,.?"||R
  224.          Type "The quick brown fox jumps over the lazy dog. ÄÖÜäöüß"||R||R
  225.  
  226.          Font SoftSans
  227.          Type "ERWEITERTER SCHRIFTCODE"||R
  228.          Font FontName
  229.          j=0
  230.          Do i=1 to 4
  231.             Do k=128+j to 159+j
  232.                Type d2c(k)
  233.             End
  234.             Type R
  235.             j=j+32
  236.          End
  237.       End
  238.  
  239.       View
  240.  
  241.       /* Nur Speichern */
  242.       If wgw~=3 then 
  243.          Save NameFont
  244.  
  245.       /* Speichern+Drucken */
  246.       If wgw=2 then 
  247.          Print
  248.  
  249.       /* Nur Drucken */
  250.       If wgw=3 then
  251.          Print
  252.  
  253.       Cleardoc force
  254.    END
  255.    else do
  256.       'ShowMessage 1 1 "FW kann diesen Font nicht anzeigen..." "Es ist kein FW typischer Font..." "" "Okay" "" ""'
  257.    end
  258. END
  259.  
  260. Ende:
  261. Address(FW)
  262. If cl=1 then 'ShowMessage 2 1 "Die Dokumente sind im FWDocs-Drawer" "zu finden. Erkennbar am «Codes-.....«" "Vielen Dank für die Benutzung." "@-`-" "Bitte" ":-))"'
  263. If cl=2 then 'ShowMessage 2 1 "Die Dokumente sind im FWDocs-Drawer" "zu finden. Erkennbar am «Layout-.....«" "Vielen Dank für die Benutzung." "@-`-" "Bitte" ":-))"'
  264. Address command "delete ram:fonts QUIET"
  265. EXIT
  266.  
  267. BREAK_C:
  268. 'ShowMessage 1 1 "Makro-Abbruch..." "" "" "Ich weiß..." "" ""'
  269. View
  270. address "REXX"
  271. CLOSE("file")
  272. Address command "delete ram:fonts QUIET"
  273. EXIT
  274.